home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 8198 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.1 KB

  1. Path: anvil.ugrad.cs.ubc.ca!not-for-mail
  2. From: c2a192@ugrad.cs.ubc.ca (Kazimir Kylheku)
  3. Newsgroups: comp.lang.c,comp.unix.programmer
  4. Subject: Re: How to find out if the child process has done exec()
  5. Followup-To: comp.unix.programmer
  6. Date: 1 Mar 1996 18:48:31 -0800
  7. Organization: Computer Science, University of B.C., Vancouver, B.C., Canada
  8. Distribution: na
  9. Message-ID: <4h8ctvINNgr1@anvil.ugrad.cs.ubc.ca>
  10. References: <DnM3An.60M@seas.ucla.edu>
  11. NNTP-Posting-Host: anvil.ugrad.cs.ubc.ca
  12.  
  13. In article <DnM3An.60M@seas.ucla.edu>,
  14. Orachat Chieu <orachat@cirrus.seas.ucla.edu> wrote:
  15.  >Hi:
  16.  >
  17.  >Is there a way for the parent process to find out if the child
  18.  >process that it has forked has done an exec() or not?  Thank you.
  19.  
  20. This is not necessary, because the child executes the same code as the parent
  21. until the exec() happens. In this code, you can communicate to the parent that
  22. you are _about to_ do an exec. However, after the exec there is no notification
  23. to the parent that it has been done. Once you exec(), your code is replaced by
  24. the new program and control passes to it.
  25.  
  26. (follow-up set to comp.unix.programmer)
  27. -- 
  28.  
  29.